package com.rfid.assistant.bean;

public class DoorConfig {
    public static final int CMD_READ_CONFIG = 0x01;
    public static final int CMD_WRITE_CONFIG = 0x02;

    public static final int SUB_CMD_VOL = 1;
    public static final int SUB_CMD_WORK_MODE = 2;
    public static final int SUB_CMD_WARN_MODE = 3;
    public static final int SUB_CMD_DOOR_ADDR = 4;
    public static final int SUB_CMD_AFI = 5;
    public static final int SUB_CMD_DOOR_COUNT = 6;
    public static final int SUB_CMD_NET_WORK_MODE = 7;
    public static final int SUB_CMD_INOUT = 8;
    public static final int SUB_CMD_IP = 9;
    public static final int SUB_CMD_SERVER_IP = 10;
    public static final int SUB_CMD_AFIP = 11;
    public static final int SUB_CMD_POWER = 12;

    int vol;//音量为1~3。3代表最大音量
    int workMode;//模式为1~3。1代表独立模式，2代表主从模式主门，3代表主从模式从门
    int warnMode;//模式为1~3。1代表AFI模式，2代表EAS模式，3代表AFI+EAS模式；
    int doorAddr;//显示（A d d r - 1）,只需要设置带控制板的门（A门）地址，设置范围为1、3、5、7、9......，
    int afi;//显示（A F I – 0 7），AFI报警值为00~FF。常用值为07；
    int doorCount;//显示（t o t - - 1），安全门总片数为1~10。根据实际门片数设定，未设置正确的话，会影响正常工作
    int netWorkMode;//网络工作模式为1~3。1为正常报警，并通过网络上传报警图书UID；2为手机借还模式，上传报警图书UID，系统判断是否报警；3为关闭网络功能，如无需上报报警图书信息时可以使用。
    int inOut;//进出方向默认值为1，改为2对换上报数据的进出方向。
    String ip;
    String serverIp;
    int afiP;//同afi
    int power;//显示（PO- - 0 4），功率范围1~8。

    public int getPower() {
        return power;
    }

    public void setPower(int power) {
        this.power = power;
    }

    public int getVol() {
        return vol;
    }

    public void setVol(int vol) {
        this.vol = vol;
    }

    public int getWorkMode() {
        return workMode;
    }

    public void setWorkMode(int workMode) {
        this.workMode = workMode;
    }

    public int getWarnMode() {
        return warnMode;
    }

    public void setWarnMode(int warnMode) {
        this.warnMode = warnMode;
    }

    public int getDoorAddr() {
        return doorAddr;
    }

    public void setDoorAddr(int doorAddr) {
        this.doorAddr = doorAddr;
    }

    public int getAfi() {
        return afi;
    }

    public void setAfi(int afi) {
        this.afi = afi;
    }

    public int getDoorCount() {
        return doorCount;
    }

    public void setDoorCount(int doorCount) {
        this.doorCount = doorCount;
    }

    public int getNetWorkMode() {
        return netWorkMode;
    }

    public void setNetWorkMode(int netWorkMode) {
        this.netWorkMode = netWorkMode;
    }

    public int getInOut() {
        return inOut;
    }

    public void setInOut(int inOut) {
        this.inOut = inOut;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public String getServerIp() {
        return serverIp;
    }

    public void setServerIp(String serverIp) {
        this.serverIp = serverIp;
    }

    public int getAfiP() {
        return afiP;
    }

    public void setAfiP(int afiP) {
        this.afiP = afiP;
    }

    @Override
    public String toString() {
        return "DoorConfig{" +
                "vol=" + vol +
                ", workMode=" + workMode +
                ", warnMode=" + warnMode +
                ", doorAddr=" + doorAddr +
                ", afi=" + afi +
                ", doorCount=" + doorCount +
                ", netWorkMode=" + netWorkMode +
                ", inOut=" + inOut +
                ", ip='" + ip + '\'' +
                ", serverIp='" + serverIp + '\'' +
                ", afiP=" + afiP +
                ", power=" + power +
                '}';
    }
}
